// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import FastClick from 'fastclick'
import router from './router'
import App from './App'

import axios from 'axios'
import Qs from 'qs'

Vue.config.productionTip = false
Vue.prototype.$ajax = axios.create({
	baseURL: 'http://192.168.100.62:8025',
	/*timeout: 5000,*/
	/*withCredentials: true,*/
	// 这时候我们通过Qs.stringify转换为表单查询参数
	transformRequest: [function(data) {
		data = Qs.stringify(data)
		return data
	}],
	// 设置Content-Type
	headers: {
		'Content-Type': 'application/x-www-form-urlencoded'
	}
})

window.Bus = new Vue();

FastClick.attach(document.body)

Vue.config.productionTip = false



/* eslint-disable no-new */
var vm = new Vue({
	router,
	render: h => h(App)
}).$mount('#app-box')